# -*- coding: utf-8 -*-#
#-------------------------------------------------------------------------------
# 建立者:        博智科技  
# Name:         demo1723
# Description:
# Author:       yzl
# Date:         2019-02-08
#-------------------------------------------------------------------------------

import random
from time import sleep
import _thread as thread

def func(a,b):
    print(a,b)
    print()
    sleep(random.randint(2,5))

if __name__ =='__main__':
    print('开始多线程...')

    for i in range(8):
        # 启动了8个线程
        thread.start_new_thread(func,(i + 1 , 'A' * (i + 1)))

    print('主线程执行完毕')

# input('主线程等待中...')